
ARCH    = arm64
CROSS_COMPILE   = aarch64-none-linux-gnu-

KERN_DIR =  /home/andy/emb240103/e2000d/kernel/local/phytium-linux-kernel

build: kernel_modules

kernel_modules:
	make -C $(KERN_DIR) M=`pwd` modules
	$(CROSS_COMPILE)gcc -lpthread -o app_mpu6500 app_mpu6500.c

clean:
	make -C $(KERN_DIR) M=`pwd` modules clean
	rm -rf modules.order  app_mpu6500 *.o
	
obj-m += spi_mpu6500.o
